//Source file: D:\\aaa\\com\\ce\\pms\\renovation\\model\\RenovateLicenceDO.java

package com.ce.pms.renovation.model;

import java.util.Date;

import javax.persistence.AttributeOverride;
import javax.persistence.Column;
import javax.persistence.Embedded;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToOne;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import com.ce.pms.common.model.HmEmployeeDomain;
import com.ce.pms.common.model.SysInfo;
import com.sitechasia.webx.core.model.IDomainObject;

/**
 * 实体名称:装修许可证 关联数据表:RM_RENOVATE_LICENCE
 *
 * @author yandawei
 * @CreateDate:2008-12-17
 */
@Entity
@Table(name = "RM_RENOVATE_LICENCE")
public class RenovateLicenceDO implements IDomainObject {

	/**
	 *
	 */
	private static final long serialVersionUID = 6617555421915827694L;

	/**
	 * 主键
	 */
	@Id
	@GeneratedValue
	@Column(name = "RENOVATE_LICENCE_ID")
	private Long keyword;

	/**
	 * 装修申办对象
	 */
	@OneToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "RENOVATE_REQUISITION_ID")
	private RenovateRequisitionDO renovateRequisition;

	/**
	 * 许可证号，默认为装修申请号
	 */
	@Column(name = "LICENCE_NUMBER", nullable = false, length = 13)
	private String licenceNumber;

	/**
	 * 发证状态 001-已发，002-未发
	 */
	@Column(name = "STATE", nullable = false, length = 3)
	private String state;

	/**
	 * 装修开始日期
	 */
	@Temporal(TemporalType.DATE)
	@Column(name = "BEGIN_DATE", nullable = false)
	private Date beginDate;

	/**
	 * 装修结束日期
	 */
	@Temporal(TemporalType.DATE)
	@Column(name = "END_DATE", nullable = false)
	private Date endDate;

	/**
	 * 备注
	 */
	@Column(name = "REMARK", nullable = false, length = 200)
	private String remark;

	/**
	 * 办理人
	 */
	@OneToOne
	@JoinColumn(name = "EMPLOYEE_ID")
	private HmEmployeeDomain transactor;

	/**
	 * 办理日期
	 */
	@Temporal(TemporalType.DATE)
	@Column(name = "TRANSACT_DATE", nullable = false)
	private Date transactDate;

	/**
	 * 系统信息
	 */
	@Embedded
	@AttributeOverride(name="sysDate",column=@Column(name="SYS_DATE"))
	private SysInfo sysInfo;



	public RenovateLicenceDO(Long keyword) {
		super();
		this.keyword = keyword;
	}

	public Date getBeginDate() {
		return beginDate;
	}

	public void setBeginDate(Date beginDate) {
		this.beginDate = beginDate;
	}

	public Date getEndDate() {
		return endDate;
	}

	public void setEndDate(Date endDate) {
		this.endDate = endDate;
	}

	public Long getKeyword() {
		return keyword;
	}

	public void setKeyword(Long keyword) {
		this.keyword = keyword;
	}

	public String getLicenceNumber() {
		return licenceNumber;
	}

	public void setLicenceNumber(String licenceNumber) {
		this.licenceNumber = licenceNumber;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public RenovateRequisitionDO getRenovateRequisition() {
		return renovateRequisition;
	}

	public void setRenovateRequisition(RenovateRequisitionDO renovateRequisition) {
		this.renovateRequisition = renovateRequisition;
	}

	public String getState() {
		return state;
	}

	public void setState(String state) {
		this.state = state;
	}

	public SysInfo getSysInfo() {
		return sysInfo;
	}

	public void setSysInfo(SysInfo sysInfo) {
		this.sysInfo = sysInfo;
	}

	public Date getTransactDate() {
		return transactDate;
	}

	public void setTransactDate(Date transactDate) {
		this.transactDate = transactDate;
	}

	public HmEmployeeDomain getTransactor() {
		return transactor;
	}

	public void setTransactor(HmEmployeeDomain transactor) {
		this.transactor = transactor;
	}

	/**
	 * @roseuid 49473A9F03C8
	 */
	public RenovateLicenceDO() {

	}
}
